package com.yongbao.model.dtomapper;

import com.yongbao.model.domain.AdminDO;
import com.yongbao.model.request.AdminRequest;
import com.yongbao.model.vo.AdminVO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

/**
 * @author zhanghong
 */
@Mapper(componentModel = "spring")
public interface AdminDtoMapper {

    AdminDtoMapper INSTANCE = Mappers.getMapper(AdminDtoMapper.class);

    /**
    * DO to VO
    * @param adminDO
    * @return
    */
    AdminVO do2VO(AdminDO adminDO);

    /**
     * request to DO
     * @param request
     * @return
     */
    AdminDO request2DO(AdminRequest request);
}
